package com.hgt.cloudAlibaba.service;

import com.hgt.cloudAlibaba.domain.CommonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.math.BigDecimal;

/**
 * @author HuangGaoTao 929507053@qq.com
 * @Created: 2021/7/21 17:24
 */
@Component
@FeignClient("seata-account-service")
public interface AccountService {

    @PostMapping("/account/decrease")
     CommonResult decrease(@RequestParam("userId") Long userId, @RequestParam("money") BigDecimal money);
}
